package com.tulingxueyuan.sentinelnew.interceptor.feign;

import feign.RequestInterceptor;
import feign.RequestTemplate;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
 * @author :tangweiliang
 * @date : 2023/2/5 14:34
 * 未来的你会感谢现在努力的自己
 */
public class CustomFeignIntercptor implements RequestInterceptor {
    Logger logger = LoggerFactory.getLogger(this.getClass());

    @Override
    public void apply(RequestTemplate template) {
        template.header("xxx", "xxx");
        template.query("id", "111");
        template.uri("/9");

        logger.info("feign拦截器!");
    }
}
